package com.flurry.android;

import android.content.Context;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.text.TextUtils;
import com.flurry.android.caching.ObjectData;

public class CacheDBServerOperations extends CacheDBOperations
{
  public CacheDBServerOperations(Context paramContext, String paramString)
  {
    this.cD = dw.e(paramContext, paramString);
    this.TAG = "CacheServerOperationsDB";
    this.cE = "serverDataTable";
  }

  public ObjectData getObjectById(String paramString)
  {
    Cursor localCursor = this.cD.getReadableDatabase().query(this.cE, null, null, null, null, null, null);
    ObjectData localObjectData;
    String str1;
    String str3;
    if (localCursor.moveToFirst())
    {
      int i = localCursor.getColumnIndex("objectsId");
      int j = localCursor.getColumnIndex("objectsLocalId");
      int k = localCursor.getColumnIndex("collectionName");
      int m = localCursor.getColumnIndex("key");
      int n = localCursor.getColumnIndex("value");
      localObjectData = null;
      do
      {
        str1 = localCursor.getString(i);
        String str2 = localCursor.getString(j);
        str3 = localCursor.getString(k);
        String str4 = localCursor.getString(m);
        String str5 = localCursor.getString(n);
        if ((paramString.equals(str1)) || (paramString.equals(str2)))
        {
          if (localObjectData == null)
          {
            if (!TextUtils.isEmpty(str3))
              break;
            localObjectData = new ObjectData(str1);
          }
          localObjectData.addKeyValue(str4, str5);
        }
      }
      while (localCursor.moveToNext());
    }
    while (true)
    {
      localCursor.close();
      return localObjectData;
      localObjectData = new ObjectData(str1, str3);
      break;
      localObjectData = null;
    }
  }
}

/* Location:           E:\android\Toy Defense 2_dex2jar.jar
 * Qualified Name:     com.flurry.android.CacheDBServerOperations
 * JD-Core Version:    0.6.2
 */